package com.matt.foundation.vo.course;

import com.matt.foundation.DO.ChildrenCourseItemDO;
import com.matt.foundation.DO.CoursePlanDO;
import com.matt.foundation.constant.CourseConstant;
import com.matt.foundation.utils.DateUtil;
import com.matt.foundation.vo.ChildrenListVo;
import lombok.Data;

import java.util.Date;
import java.util.List;
import java.util.stream.Collectors;

/**
 * *******************************
 * Created by Ron.
 * form com.matt
 * on 2017/9/19
 * *******************************
 */
@Data
public class CoursePlanEarlyListVo {

    private String coursePlanClassesId;

    private Date courseDate;

    private Date beginTime;

    private Date endTime;

    private Integer prepareStatus;

    private Integer courseStatus;

    private Integer courseType;

    private String courseName;

    private String classesName;

    private String courseEarlyId;

    private Long childNum;
    
    private Integer templateType;


    public static CoursePlanEarlyListVo planOf(CoursePlanDO plan, Long childNum) {
        CoursePlanEarlyListVo vo = new CoursePlanEarlyListVo();
        vo.setCoursePlanClassesId(plan.getId());
        vo.setCourseDate(plan.getCourseDate());
        vo.setBeginTime(plan.getBeginTime());
        vo.setEndTime(plan.getEndTime());
        vo.setPrepareStatus(plan.getPrepareStatus());
        vo.setCourseType(plan.getCourseType());
        vo.setCourseName(plan.getCourseName());
        vo.setClassesName(plan.getClassesName());
        vo.setCourseStatus(plan.getCourseStatus());
        vo.setTemplateType(plan.getTemplateType());
        vo.setChildNum(childNum);
        vo.setCourseEarlyId(plan.getCourseId());
        return vo;
    }
}
